# TODO: This is workaround for downstream osp17 job, TripleO now defaults to
# libvirt's "modular daemons" but this required libvirt > 7.4, this is a
# temporary workaround to move back to monolithic modular libvirt daemon till
# we move RHOSP17 to RHEL9 which will provide  libvirt > 7.4.
# Details in https://bugzilla.redhat.com/show_bug.cgi?id=2021536
{% if ansible_distribution in ["RedHat"] and osp_release|default('') == 'rhos-17' %}
resource_registry:
  OS::TripleO::Services::NovaLibvirt: /usr/share/openstack-tripleo-heat-templates/deployment/deprecated/nova/nova-libvirt-container-puppet.yaml
{% endif %}
parameter_defaults:
  CertmongerCA: local
  CloudName: {{ standalone_ip }}
  ContainerCli: {{ standalone_container_cli }}
  ContainerImagePrepareDebug: true
  ControlPlaneStaticRoutes: []
  Debug: true
  ConfigDebug: {{ standalone_tripleo_deploy_debug_arg }}
  DockerPuppetDebug: {{ standalone_tripleo_deploy_debug_arg }}
  DeploymentUser: {{ undercloud_user }}
  DnsServers: {{ undercloud_undercloud_nameservers | to_json }}
  DockerInsecureRegistryAddress:
  - {{ local_docker_registry_host }}:8787
{% if build_container_images|default(false)|bool %}
  - {{ local_registry_ip }}:{{ local_registry_port }}
{% endif %}
{% if job.consumer_job | default(false) | bool %}
  - {{ job.registry_ip_address_branch[release] }}:{{ local_registry_port }}
{% else %}
  - quay.io
{% endif %}
{% if undercloud_docker_registry_mirror is defined and undercloud_docker_registry_mirror %}
  DockerRegistryMirror: {{undercloud_docker_registry_mirror}}
{% endif %}
  LocalContainerRegistry: {{ local_docker_registry_host }}
  MasqueradeNetworks:
    {{ standalone_network }}.0/{{ standalone_network_prefix }}:
    - {{ standalone_network }}.0/{{ standalone_network_prefix }}
# Set machine type if default is not supported on current OS
# see https://bugzilla.redhat.com/show_bug.cgi?id=2110535
{% if nova_hw_machine_type is defined and nova_hw_machine_type %}
  NovaHWMachineType: {{ nova_hw_machine_type }}
{% endif %}
  NeutronPublicInterface: {{ standalone_interface }}
{% if standalone_neutron_bridge_mappings is defined and standalone_neutron_bridge_mappings %}
  NeutronBridgeMappings: {{ standalone_neutron_bridge_mappings }}
{% endif %}
{% if standalone_neutron_physical_bridge is defined and standalone_neutron_physical_bridge %}
  NeutronPhysicalBridge: {{ standalone_neutron_physical_bridge }}
{% endif %}
# TODO: This is workaround for https://bugzilla.redhat.com/show_bug.cgi?id=2006409, Remove this
# once this bug is fixed.
  NovaLibvirtNumPciePorts: 12
  StandaloneCtlplaneLocalSubnet: ctlplane-subnet
  StandaloneCtlplaneSubnets:
    ctlplane-subnet:
      DhcpRangeEnd: {{ standalone_network }}.40
      DhcpRangeStart: {{ standalone_network }}.20
      NetworkCidr: {{ standalone_network }}.0/{{ standalone_network_prefix }}
      NetworkGateway: {{ standalone_ip }}
  StandaloneEnableRoutedNetworks: false
  StandaloneHomeDir: {{ working_dir }}
  InterfaceLocalMtu: 1500
  NovaComputeLibvirtType: {{ standalone_libvirt_type }}
  SELinuxMode: {{ standalone_selinux_mode }}
  NeutronDnsDomain: 'openstackgate.local'
{% if job is defined and job.standalone_ntp_servers is defined %}
  NtpServer: {{ job.standalone_ntp_servers }}
{% endif %}
